#!/bin/bash
#

read -p "输入用户名：" user
#判断用户是否存在
if id ${user} &> /dev/dull; then
    #获取用户的uid，gid
    u_id=$(id -u ${user})
    g_id=$(id -g ${user})
    if [ $u_id -eq $g_id ]; then
	echo "Good"
    else 
	echo "Bad"
    fi
else 
    echo "用户${user}不存在"
fi
